{extend name="admin@public/base" /}
 
{block name="main-content"}
<div class="page-content">
        <form name="admin_list_sea" class="form-search form-inline" id="list-filter" method="post"  action="{:url('index')}">
			<div class="row maintop">
				 
                      <select name="mbdir" id="mbdir" class="form-control" >
                          <option value="{if condition="$kpath eq ''"}selected{/if}">选择目录</option>
                                     {foreach name="jpath" item="jt"}
                                         <option value="{:base64_encode($jt)}" {if condition="$kpath eq $jt"}selected{/if}>{$jt}</option>
                                     {/foreach}
                       </select>
                       <script language="javascript">
                                 $("#mbdir").change(function(){
                                       var jkUrl =  "{:url('index',['mbdir'=>'_MBDIR_'])}";
                                       jkUrl = jkUrl.replace('_MBDIR_',$(this).val());
                                       location.href = jkUrl;
                                 });
                      </script>  
             
              
					<a href="{:url('add')}">
						<button type="button" class="btn btn-xs all-btn btn-purple">
							<span class="ace-icon fa fa-globe icon-on-right bigger-110"></span>
							添加模板
						</button>
					</a>
                    
                    
				 


			</div>
		</form>

        <div class="row">
                <div class="col-xs-12">
                    <div>
                        <form id="alldel" name="alldel" method="post" action="{:url('admin/template/del')}" >
                            <input name="p" id="p" value="{:input('p',1)}" type="hidden" />
                            <div class="table-responsive">
                                <table class="table table-striped table-bordered table-hover" id="dynamic-table">
                                    <thead>
                                    <tr>
                                        <th class="hidden-xs center" width="5%">
                                            <label class="pos-rel">
                                                <input type="checkbox" class="ace"  id='chkAll' onclick='CheckAll(this.form)' value="全选"/>
                                                <span class="lbl"></span>			
                                                                                            </label>											</th>
                                                                                            
                                    <th >模板地址</th>
                                    <th class="hidden-xs center" width="9%">创建时间</th>
                                    <th class="hidden-xs center" width="9%">修改时间</th>
                                    <th width="8%" style="border-right:#CCC solid 1px;">操作</th>
                                         
                                    </tr>
                                    </thead>
    
                                    <tbody id="ajax-data">
                                        {include file="template/ajax_index"/}
                                    </tbody>
                                </table>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div><!-- /.page-content -->

 
{/block}
{block name="scripts"}
<script language="javascript">
     function do_jedit(id){ 
	     edit({w:1024,h:870,title:'编辑模板',url:'./edit/id/'+id+'.html'});
     }
</script> 
{/block}
 